home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 4 / Apprentice-Release4.iso / Source Code / C / Applications / µSim 1.0.5 / FabLibsƒ / InitCursorBalloon.c < prev    next >
Encoding:
Text File  |  1995-07-19  |  978 b   |  38 lines  |  [TEXT/CWIE]

  1. /*
  2. Copyright © 1993,1994 by Fabrizio Oddone
  3. ••• ••• ••• ••• ••• ••• ••• ••• ••• •••
  4. This source code is distributed as freeware: you can copy, exchange, modify this
  5. code as you wish. You may include this code in any kind of application: freeware,
  6. shareware, or commercial, provided that full credits are given.
  7. You may not sell or distribute this code for profit.
  8. */
  9.  
  10. //#pragma load "MacDump"
  11.  
  12. #include    "InitCursorBalloon.h"
  13. #include    "CursorBalloon.h"
  14. #include    "FabWList.h"
  15.  
  16. #if    !defined(FabNoSegmentDirectives)
  17. #pragma segment Init
  18. #endif
  19.  
  20. /* Initializes the manager; should be called after initializing QuickDraw, etc.
  21. should be put into the initialization segment of the application */
  22.  
  23. OSErr InitCursorBalloonManager(void)
  24. {
  25. register OSErr err = appMemFullErr;
  26.  
  27. InitFabWListManager();
  28. mouseRgn = NewRgn();
  29. wideOpenRgn = NewRgn();
  30. if (mouseRgn && wideOpenRgn) {
  31.     ForceMouseMovedEvent();
  32.     SetRectRgn(wideOpenRgn, -32765, -32765, 32765, 32765);
  33.     err = noErr;
  34.     }
  35. return err;
  36. }
  37.  
  38.